home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Cream of the Crop 11
/
Cream of the Crop 11-1.iso
/
utility
/
pwg_key.zip
/
KRS100.ZIP
/
MAKEKEY.WCC
< prev
next >
Wrap
Text File
|
1995-05-18
|
3KB
|
91 lines
' MakeKey.wcc
' By Mark Schwandt & William Mantz
' Public Domain 1995.
' For use with the KRS Key Registration System by Mark Schwandt
' and William Mantz
'
Dim CfgBBS as String*30
Dim Expand as Integer
Dim Totals as Long
Dim Hack as String
Dim ProgID as LONG
Dim BBSRegNum as STRING*7
Dim StrChkSum as Long
Dim ProgChkSum AS LONG
DIM BBSId as LONG
' first, Get the BBS Name from MakeWild's Record information.
' Trim it and make it all UPPER CASE, then Get the CheckSum of it.
//********** Decoder **********
Start:
CLS
PRINT"@7F@┌@78@─────────────────────────────────────────────────────────────────────────────┐@7F@"
PRINT"@7F@│ MakeKey Ver 1.0 @78@│@7F@"
PRINT"@7F@│ @78@│@7F@"
PRINT"@7F@│ @74@Enter WC! BBS Name @0E@[ ]@7F@ @78@│@7F@"
PRINT"@7F@│ @78@│@7F@"
PRINT"@7F@│ @74@Enter the WC! Registration No.@0E@[ ]@7F@ @78@│@7F@"
PRINT"@7F@│ @78@│@7F@"
PRINT"@7F@│ @74@Enter the Program ID Code (1-99999) @0E@[ ]@7F@ @78@│@7F@"
PRINT"@7F@│ @78@│@7F@"
PRINT"@7F@│ @74@The Key for this Package is :@7F@ @78@│@7F@"
PRINT"@7F@│ @78@│@7F@"
PRINT"@7F@└─────────────────────────────────────────────────────────────────────────────@78@┘@09@"
Locate 4,36:PRINT"@0A@";:CfgBBS = InputMask("","XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX")
Locate 6,47:PRINT"@0B@";:BBSregNum = InputMask("","99-9999")
Locate 8,53:PRINT"@0D@";: ProgId = InputNumber("",1,99999)
StrChkSum = 0
ProgChkSum = 0
BBSRegNum = TRIM(BBSRegNum)
BBSRegNum = UCASE(BBSRegNum)
CfgBBS = TRIM(CfgBBS)
CfgBBS = UCASE(CfgBBS)
For Expand = 1 to Len(cfgBBS)
StrChkSum = StrChkSum + Asc(Mid(cfgBBS,Expand,1))
Next Expand
' StrChkSum has the CheckSum of the BBS name.
' Next, Get the BBS Reg Number from MakeWild's record Information.
' and Get the ChkSum of it.... ProgChkSum contains the iD.
ProgChkSum = 0
For Expand = 1 to Len(BBSRegNum)
ProgChkSum = ProgChkSum + Asc(Mid(BBSRegNum,Expand,1))
Next Expand
' Add the cfgBBS CheckSum and the BBS ID checkSum together.
ProgChkSum = ProgChkSum + StrChkSum
' Multiply the CheckSum by the Prime Number 7
ProgChkSum = ProgChkSum * 7
' Multiply the ProgChkSum by the Program's custom ID number.
ProgChkSum = ProgChkSum * ProgId
' Add the Calculated CheckSum by Program's Custom ID Number.
ProgChkSum = ProgChkSum + ProgId
' -------------------------------------------------------------
Locate 10,45
PRINT FormatNumber(ProgChkSum, "##########")
Locate 13,1
Print "@0F@"
If InputYesNo("Do you want to generate another Key? <Y/N>",True) Then
GOTO Start
END IF
END